{% extends 'table_base.html' %}
{% load crispy_forms_tags %}

{% block crumbs %}
    <div role="tablist" class="tw:tabs tw:tabs-sm">
        <a role="tab" class="tw:tab tw:h-fit {% if headerline_tab_sec == "audit-user-registry" %}tw:tab-active tw:font-bold{% endif %}" href="{% url 'audit:user' %}">{% trans '用户注册审核' %}</a>
        <a role="tab" class="tw:tab tw:h-fit {% if headerline_tab_sec == "invite-code" %}tw:tab-active tw:font-bold{% endif %}" href="{% url 'user:management/invite-code' %}">{% trans '邀请码管理' %}</a>
    </div>
{% endblock %}

{% block crumbs-right %}
    {% if headerline_tab_sec == "audit-user-registry" %}
        <a class="by6-crumbs-action-btn" id="save-changes">{% trans '保存更改' %}</a>
    {% elif headerline_tab_sec == "invite-code" %}
        <a class="by6-crumbs-action-btn" id="delete-selected-btn">{% trans '删除邀请码' %}</a>
        <a class="by6-crumbs-action-btn" onclick="by6_modal_xl.showModal()">{% trans '新建邀请码' %}</a>
    {% endif %}

    {% block crumbs-right-extend %}
    {% endblock %}
{% endblock %}


{% block body-sidebar-menu %}
    {% include 'components/sidebar/management.html' %}
{% endblock %}

{% block by6-modal-xl-body %}
    {% if headerline_tab_sec == "invite-code" %}
        {% crispy form %}
    {% endif %}
{% endblock %}

